|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectPER.exhibit.Sequencer
Controls the sequence of actions in a rover mission.
Field Summary | |
static int |
ERROR
mission ended due to rover error |
static int |
INCOMPLETE
mission terminated early: tried to leave the exhibit |
static int |
INTERRUPTED
mission terminated early: ran into something early (also for e-stop) |
static int |
NO_MISSION
no missions have been run; sequencer is waiting for a new mission |
static int |
NO_ROCK
mission terminated early: no rock was found |
static int |
POSSIBLE_ERROR
mission ended due to a possible error. |
static int |
RUNNING
mission is still running |
static int |
SUCCESS
mission completed successfully |
Constructor Summary | |
Sequencer(Rover rov)
Creates a new instance of Sequencer |
Method Summary | |
Action |
getCurrentAction()
Returns the Action that is currently being executed, or null if no such Action exists. |
int |
getLastMissionAngleToRock()
Returns the angle (in degrees) that the rover had to turn to find the rock, after turning and driving as told. |
int |
getLastMissionDist()
Return the distance (in centimeters) that the rover traveled in the last mission. |
int |
getLastMissionDistToRock()
Return the distance (in centimeters) that the rover traveled beyond the original distance it was told. |
java.awt.image.BufferedImage |
getLastMissionImage()
Returns the image taken by AnalyzeRock or, if that image is null, the last image taken. |
java.awt.image.BufferedImage |
getLastMissionNoUVImage()
Returns the image taken by AnalyzeRock or, if that image is null, the last image taken. |
int |
getLastMissionTime()
Return the time (in milliseconds) that the last mission took to complete. |
int |
getStatus()
Return the current status of the sequencer (for exmaple: RUNNING ). |
boolean |
runMission(int turnDegrees,
int driveCm)
Begin execution of a mission. |
boolean |
runMission(int turnDegrees,
int driveCm,
boolean findRock)
Begin execution of a mission. |
void |
setMissionProgressPanel(MissionProgressPanel panel)
Set the MissionProgressPanel that the sequencer should use as a visual display of the current mission's status. |
void |
setStatus(int s)
hack for displaying error message when error in panorama |
void |
stop()
Immediately stop the current mission. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int NO_MISSION
public static final int RUNNING
public static final int SUCCESS
public static final int NO_ROCK
public static final int INCOMPLETE
public static final int INTERRUPTED
public static final int ERROR
public static final int POSSIBLE_ERROR
Constructor Detail |
public Sequencer(Rover rov)
Method Detail |
public boolean runMission(int turnDegrees, int driveCm)
turnDegrees
- the number of degrees to turn (greater than 0 is left)driveCm
- the number of centimeters to drive
stop
first)public boolean runMission(int turnDegrees, int driveCm, boolean findRock)
turnDegrees
- the number of degrees to turn (greater than 0 is left)driveCm
- the number of centimeters to drivefindRock
- indicates whether or not to search for a rock at the end of
the mission
stop
first)public int getStatus()
RUNNING
).
public void setStatus(int s)
public void stop()
public Action getCurrentAction()
public void setMissionProgressPanel(MissionProgressPanel panel)
public int getLastMissionTime()
public int getLastMissionDist()
public int getLastMissionDistToRock()
public int getLastMissionAngleToRock()
public java.awt.image.BufferedImage getLastMissionImage()
public java.awt.image.BufferedImage getLastMissionNoUVImage()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |